﻿<%@ Page Title="" Language="C#" MasterPageFile="~/back/Site.master" AutoEventWireup="true"
    CodeFile="ViewArchitects.aspx.cs" Inherits="back_ViewArchitects" %>

<asp:Content ID="Content1" ContentPlaceHolderID="HeadContent" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="Server">
    <div class="page-header">
        <h1>
            View Architects</h1>
    </div>
    <div id="divRed" runat="server">
    </div>
    <div id="divGreen" runat="server">
    </div>
    <asp:GridView ID="grdArchitect" runat="server" AutoGenerateColumns="False" Width="100%"
        CssClass="table table-striped table-bordered" OnRowDataBound="grdArchitect_RowDataBound"
        OnRowCommand="grdArchitect_RowCommand" PageSize="3" OnPageIndexChanging="grdArchitect_PageIndexChanging"
        AllowPaging="true">
        <Columns>
            <asp:TemplateField HeaderText="Name">
                <ItemTemplate>
                    <asp:Label ID="hdnArchitectId" Style="display: none;" runat="server" Text='<%#Eval("Id") %>'></asp:Label>
                    <asp:Label ID="lblName" runat="server" Text='<%# Eval("Firm") %>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Employees">
                <ItemTemplate>
                    <asp:Label ID="lblNoOfEmployees" runat="server" Text='<%#Eval("NoOfEmployees") %>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Founded Year">
                <ItemTemplate>
                    <asp:Label ID="lblFoundedYear" runat="server" Text='<%#Eval("FoundedYear") %>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Specialization">
                <ItemTemplate>
                    <asp:Label ID="lblSpecialization" runat="server" Text='<%#Eval("Specialization") %>'></asp:Label>
                </ItemTemplate>
            </asp:TemplateField>
            <asp:TemplateField HeaderText="Actions">
                <ItemTemplate>
                    <asp:Button ID="btnEdit" runat="server" CssClass="btn btn-info" Text="Edit" CommandName="EditArchitect"
                        OnClientClick="return confirm('Do you want to edit this content?')" />
                    &nbsp;&nbsp;
                    <asp:Button ID="btnDelete" runat="server" CssClass="btn btn-danger" Text="Delete"
                        CommandName="DeleteArchitect" OnClientClick="return confirm('Do you want to delete this content?')" />
                    &nbsp;&nbsp;
                    <asp:Button ID="btnArchitecturalWorks" runat="server" CssClass="btn btn-info" Text="ArchitecturalWork" CommandName="ArchitecturalWork" />
                </ItemTemplate>
            </asp:TemplateField>
        </Columns>
        <PagerSettings Position="TopAndBottom" />
        <PagerStyle CssClass="pagination" />
    </asp:GridView>
</asp:Content>
